package adapter.testpaper;

import android.support.annotation.Nullable;
import android.view.View;
import com.chad.library.adapter.base.BaseQuickAdapter;
import com.chad.library.adapter.base.BaseViewHolder;
import java.util.List;
import bean.ChapterBean;
import student.andlei.com.student.R;

public class PopupMultiChapterAadpter extends BaseQuickAdapter<ChapterBean, BaseViewHolder> {

    public PopupMultiChapterAadpter(int layoutResId, @Nullable List<ChapterBean> data) {
        super(layoutResId, data);
    }

    @Override
    protected void convert(BaseViewHolder helper, ChapterBean item) {
        helper.setText(R.id.tv_last_layer_chapter_dialog, item.getChapter_title());
        View view = helper.getView(R.id.iv_last_layer_chapter_dialog);
        if (item.isSelectId) {
            view.setVisibility(View.VISIBLE);
        } else {
            view.setVisibility(View.INVISIBLE);
        }

    }

}
